/* 
 * To change this license header, choose License Headers in Project Properties.
 * To change this template file, choose Tools | Templates
 * and open the template in the editor.
 */
var a;
var b;
    
    $.get("http://ipinfo.io", function(response) {
        var str=response.loc.split(",");
            a=str[0];
                     b=str[1];
                   form 
                    }, "jsonp");
var map;
            function initialize() {
               
                var mapOptions = {
                    center: new google.maps.LatLng(10.843928, 106.717672),
                    zoom: 8
                };
                var map = new google.maps.Map(document.getElementById('map-canvas'),
                        mapOptions);
                  
            }
            google.maps.event.addDomListener(window, 'load', initialize);

google.maps.event.addDomListener(window, 'load', initialize);

 
	
 
	function showMap(latitude,longitude) { 
 
		var googleLatandLong = new google.maps.LatLng(latitude,longitude);
 
		var mapDiv = document.getElementById("map");
		
                
		var title = "Server Location"; 
               
		addMarker(map, googleLatandLong, title, "");
 
	}
	function addMarker(map, latlong, title, content) { 
 
		var markerOptions = {
			position: latlong, 
			map: map,
			title: title, 
			clickable: true
		};
		var marker = new google.maps.Marker(markerOptions); 
	}
 

function changeFunc() {
    showMap(a,b);
    alert(a+'   '+b);
     
}
  $(function() {
             
                $('#modaltriggerlogin').leanModal({top: 110, overlay: 0.45, closeButton: ".close"});
                $('#modaltriggerlogout').leanModal({top: 110, overlay: 0, closeButton: ".close"});    
                $('#modaltriggerlogin2').leanModal({top: 110, overlay: 0.45, closeButton: ".close"});
              
             
            });
            
  
              
function log()
{
    var form=document.getElementById('loginmodal');
                   form.style.visibility='hidden';
                                  
                   var form=document.getElementById('lean_overlay');
                   form.style.visibility='hidden';
                   form.style.display='none';
                    
                    
                  
                   var form=document.getElementById('btnDrop');
                   form.style.visibility='visible';
                   form.style.display='block';
}
function nutLog()
{
    
    var form=document.getElementById('drop1');
    form.style.display='block';
   form.style.position='absolute';
             
                                  
}
